<template>
  <div>
    <hot-table
      :data="data"
      :rowHeaders="true"
      width="100%"
      height="auto"
      :autoWrapRow="true"
      :autoWrapCol="true"
      licenseKey="non-commercial-and-evaluation"
      :contextMenu="true"
      colWidths="80"
      stretchH="all"
      :colHeaders="colHeaders"
    ></hot-table>
  </div>
</template>

<script>
export default {
  data() {
    return {
      data: [
        ["", "Ford", "Volvo", "Toyota", "Honda"],
        ["2016", 10, 11, 12, 13],
        ["2017", 20, 11, 14, 13],
        ["2018", 30, 15, 12, 13],
      ],
      colHeaders: ['年份', '总人数', '入职人数','离职人数', '板凳人数'],

    };
  },
};
</script>

<style lang="less" scoped>
.handsontable {
  width: 100%;
  background: red;
}
</style>
